<?php

namespace app\shop\validate;

class User extends \ShopValidate
{
    protected $rule = [
        'user_name' => 'require|min:5|max:30',
        'password' => 'require|length:32',
    ];

    protected $message = [
        // 'cate_name.require' => '分类名称必须',
//         'cate_name.max' => '分类名称长度不能超过30个字符',
        // 'parent_id.checkExists' => '指定的父级分类不存在',
    ];

    protected $field = [
        'user_name' => '用户名',
        'password' => '密码',
    ];

    protected $scene = [
        'save' => ['user_name', 'password'],
    ];

}
